core-data Questions
2
I'm developing an application with core data. There are many entities that uses relationships and in many of them they are the primary key.
I'm trying to use the unique constraints feature in the x...
Voiced asked 27/7, 2016 at 7:0
25
Solved
I am a little confused as to how to delete all core data in swift. I have created a button with an IBAction linked. On the click of the button I have the following:
let appDel: foodforteethAppDele...
1
Solved
A beginner here
I have seen that a SwiftData model has an id property which is a PersistentIdentifier.
https://developer.apple.com/documentation/swiftdata/persistentidentifier
Currently I don't use...
10
I am new to Core Data and I'm trying to create a caching mechanism wherein after parsing objects from the API, I save them to the data model then fetch it again to show it on the tableview. I'm try...
3
Solved
I am getting the following error while saving data to CoreData. I made this project completely simple for you to review my project. There is Local json in the project. You can download and test my ...
5
Solved
@State var documents: [ScanDocument] = []
func loadDocuments() {
guard let appDelegate =
UIApplication.shared.delegate as? AppDelegate else {
return
}
let managedContext =
appDelegate.pers...
Buckler asked 26/7, 2020 at 13:50
1
I already saw this post which is about the same warning but I already have that approach and it does not fix this issue now in iOS 17 and Xcode 15.
My use case is very simple, I have this custom tr...
3
If I want to use a custom migration policy for a given entity, I believe I have to prefix the class name by the product module name, as shown on the following image:
How can I manage to handle m...
Irrevocable asked 16/1, 2018 at 15:14
2
I have an App Group shared between my app and its widgets.
I have SwiftData's @Model, updated from the widget intent's perform() method and displayed on the app and the widget.
@MainActor
func perf...
7
Just moved to Xcode 11 and getting the following crash at launch:
CoreData: fault: One or more models in this application are using transformable properties with transformer names that are either ...
Behm asked 22/9, 2019 at 20:58
5
I have just installed Xcode 4 and I am trying to create projects that use core data. However, the checkbox to use core data is not available in any of the project templates. Has anyone else run int...
2
I'm building an app with Core Data and CloudKit. I need to detect when remote changes have been pushed to the app and are available in the local database to perform some work on the new data set. I...
12
Solved
I'm creating a Core Data model for my application. I would like to be able to look inside it to see what I have stored in there.
Is there an easier way than searching for the backing store (mine ...
2
Solved
How do I do use @FetchRequest with a parameter passed to a struct?
struct TodoItemView: View {
var todoList: TodoList
@FetchRequest(
entity: TodoItem.entity(),
sortDescriptors: [NSSortDescript...
3
I have a parent view which does a @FetchRequest and passes the FetchedResults<T> to a child view. Everything works, and the child view is able to parse through the FetchedResults. However, I ...
3
Is it possible to set an attribute to nil using NSBatchUpdateRequest? Passing NSNull() to propertiesToUpdate isn't working:
let unlockRequest = NSBatchUpdateRequest(entityName: "MyEntity")
unlockR...
1
Solved
I am using SwiftData in my project. All worked fine under Xcode 15 beta 4 in the simulator.
Since I changed to Xcode 15 beta 5 I am getting the following error multiple times:
CoreData: fault: One...
9
Solved
11
Solved
[EDIT] I was hoping that Apple would have fixed what is obviously a bug. The solution is to clear the cache, close and reopen Xcode..
I am on Xcode Beta and starting a new project and without writi...
2
I’m getting the following warnings in Xcode when building my app (app runs just fine however):
Could not associate debug note to atom
l_OBJC_LABEL_PROTOCOL_$_NSObject
Could not associate debug not...
2
I'm trying to understand the behavior of Allows External Storage property of Core Data attributes and see if it would save me from storing files in the file system manually. I wanted to see how wou...
5
Solved
I am working on a application in which we are using x.x.xcdatamodel. Now in same x.x.xcdatamodel I have added an attribute in one of the entity. The application crashes showing the message "This NS...
Jesuitism asked 21/3, 2016 at 11:57
4
Solved
I can't find a clear description of these steps in Apple docs...
I have a xcdatamodeld in my xcode project
At launch time, my app parses a XML (project resource) to fill the Core Data Store (SQLL...
Haploid asked 12/4, 2011 at 9:28
5
Solved
I'm experimenting code from https://alanquatermain.me/programming/swiftui/2019-11-15-CoreData-and-bindings/
my goal is to have DatePicker bind to Binding< Date? > which allow for nil value ins...
Valuate asked 10/12, 2019 at 17:45
2
With a List one can simply use the .onDelete modifier to remove the rows from the List. But how can we do the same in a ForEach shown within a LazyVStack. I am using SwipeCell to apply a drag gestu...
© 2022 - 2024 — McMap. All rights reserved.