Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

Postgres / laravel Question

agoldenbergagoldenberg Member, Host Rep

Hey All!

I know there are some SQL gurus here and need a small hand with an issue I'm having.

I'm inserting an array into a DB and as part of the array I'd like one value to be concat(value1, value2) but when I insert it using laravel, it gets inserted as a string.

Comments

  • smalletsmallet Member
    edited November 2015

    I don't get it, concat is meant for joining two (primitives, strings, etc) into a single string. The output will always be a string. What are the values you are trying to "join"? Like, 22 + 44 = 2244 (stored in an int)?

    Maybe you can typecast(is that a thing?) that concat output into what you want? Sorry, don't have much PHP experience for any specifics.

  • agoldenbergagoldenberg Member, Host Rep

    No was looking to join a URL with a column value (ID) figured it out on my own lol!

    Thanked by 1netomx
  • Oh, nice.

Sign In or Register to comment.