umbrellio / laravel-pg-extensions

Laravel extensions for Postgres
MIT License
90 stars 18 forks source link

Arrays #59

Closed jamesRUS52 closed 3 years ago

jamesRUS52 commented 3 years ago

Is any plans to implement array types ?

pvsaintpe commented 3 years ago

Hi, @jamesRUS52

Yes, tell me exactly what you need, we'll add it.

jamesRUS52 commented 3 years ago

It would by nice If you will implement the next data types for migration procedure integer[] charaster varying[] real[] real interval

and one more question Is it possible to work with this types in models? or use in casting like $cast = [ 'column1' => 'interval', 'column2' => 'stringArray' ]

It simple to make cast class for integer array or real array, interval not too hard too (I did that), but it is not trivial for string array postgres returns string depend on content (is space in string or not, double quote or single quote etc )

pvsaintpe commented 3 years ago

@jamesRUS52

That's interesting. Okay. Let me analyze and answer in a week.

I don't think it's difficult there.

github-actions[bot] commented 3 years ago

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days