Generally in ORM and OOP , a persistent object refers to an object that exists (or persists) in the database
Questions tagged [persistent]
771 questions
16
votes
1 answer
yesod persistent postgresql complex record
I am using persistent to save the following records (Time is UTCTime).
type Price = Int
type Volume = Int
share [mkPersist sqlSettings, mkMigrate "migrateBook"]
[persistLowerCase|
Level
limit Price
volumes [Volume]
…

Maarten
- 1,037
- 1
- 11
- 32
16
votes
3 answers
How to get generated ID after I inserted into a new data record in database using Spring JDBCTemplate?
I got a very common question when I was using Spring JDBCTemplate, I want to get the ID value after I inserted a new data record into database, this ID value will be referred to another related table. I tried the following way to insert it, but I…

Brady Zhu
- 1,305
- 5
- 21
- 43
15
votes
3 answers
zeromq persistence patterns
Who has to manages the persistent in the ZeroMQ?
When we use the ZeroMQ clients in Python language, what are the plug-ins/modules available to manage the persistent?
I would like to know the patterns to use the ZeroMQ.
user90150
15
votes
6 answers
How to clear persistent variables while keeping breakpoints in MATLAB?
Is there a way to clear all persistent variables in MATLAB functions, while keeping the breakpoints in the corresponding function files?
clear all;
and
clear functions;
both kill the breakpoints.

Philipp
- 4,659
- 9
- 48
- 69
14
votes
7 answers
Implementing a file based queue
I have an in memory bounded queue in which multiple threads queue objects. Normally the queue should be emptied by a single reader thread that processes the items in the queue.
However, there is a possibility that the queue is filled up. In such a…

serverman
- 1,314
- 5
- 22
- 39
14
votes
3 answers
Long Lived Persistent TCP Connection on the Android
I've read some articles on the web and some questions on StackOverFlow, but no one seems to have a definite answer over a) If google uses Long Lived TCP connections for Gmail, Mail etc, and b) If using it in a custom app will drain battery life ,…

Faisal Abid
- 8,900
- 14
- 59
- 91
13
votes
2 answers
Android timer that works when device is sleeping
I'm writing a sports app that needs to track the elapsed time of quarter/half/period. Elapsed time needs to be accurate to the second. The game clock needs to continue to run even if the user explicitly places the device in sleep mode by pressing…

Rich
- 201
- 3
- 9
13
votes
1 answer
Sending a persistent message in RabbitMQ via HTTP API
I want to send a persistent mesaage via HTTP API. Im using this command:
curl -u UN:PWD -H "content-type:application/json" -X POST -d'{"properties":{},"routing_key":"QueueName","payload":"HI","payload_encoding":"string", "deliverymode": 2}'…

user2340345
- 793
- 4
- 16
- 38
13
votes
1 answer
Representing sum types in sql with Persistent, and Esqueleto joins
I have been trying to figure out a sensible way to represent Haskell sum types in a SQL backend using persistent.
My target Haskell data type is along the lines of
data Widget = FooWidget Int | BarWidget T.Text
data HElement = HElement
{ name …

Michael Thomas
- 1,354
- 7
- 18
13
votes
2 answers
How do I define a composite key in Persistent
How do I declare to Persistent that I have a table the primary key of which is a combination of two fields?
For example, assume I have a table containing first_name and last_name, then in SQL syntax I'll need something like:
CONSTRAINT pk_PersonID…

Uri Barenholz
- 693
- 3
- 13
12
votes
3 answers
Shared Preferences not persistent after app restart
I found all answers here and tried all solutions, still my shared prefs are not persistent.
Here's my code:
public static void setActivated(boolean activated) {
SharedPreferences sp = Utils.getContext().getSharedPreferences(
…

Razvan
- 493
- 5
- 16
11
votes
5 answers
is there any php redis client support persistent connection?
As the title, I'm looking for a php Redis client that support persistent connection, because my web application receives a lot of requests(each request, it'll put an item in to Redis queue) and I want to avoid create new connection every request.

secmask
- 7,649
- 5
- 35
- 52
11
votes
1 answer
Behavior of saveRDS() and readRDS() in regard to objects' attributes
Do saveRDS and readRDS, correspondingly, save and restore all object's attributes, including ones created by an application (via attr)? I tried to use this approach instead of save and load, in an attempt to find a workaround for my problem linked…

Aleksandr Blekh
- 2,462
- 4
- 32
- 64
11
votes
1 answer
Using persistent from within a Conduit
First up, a simplified version of the task I want to accomplish: I have several large files (amounting to 30GB) that I want to prune for duplicate entries. To this end, I establish a database of hashes of the data, and open the files one-by-one,…

Aleksandar Dimitrov
- 9,275
- 3
- 41
- 48
11
votes
2 answers
What's the meaning of the /persistent/ directory in Magento themes?
I know it has something to do with the persistent feature of Magento, introduced in CE 1.6
But what is the in-depth meaning?
Why is Magento doubling templates?

Celldweller
- 309
- 1
- 3
- 12