← prev | next →
DesolatorMagno 2020-06-07 22:41:42
cayetanohosma 2020-06-07 22:36:55
When I try to validate an invalid set of UUIDs like this:
{
“id”: [
“cucu-cantaba-la-rana-cucu-cantaba-la”,
“0428e2ac-bdf1-4629-b4a0-b7591eb525d3”,
“0428e2ac-bdf1-4629-b4a0-b7591eb525d3”,
“0428e2ac-bdf1-4629-b4a0-b7591eb525d3”
]
}
I’m facing with the following exception:
SQLSTATE[22P02]: Invalid text representation: 7 ERROR: invalid input syntax for type uuid: “cucu-cantaba-la-rana-cucu-cantaba-la” (SQL: select count(*) as aggregate from “users” where “id” = cucu-cantaba-la-rana-cucu-cantaba-la)
Just read the error, invalid sintaxis.
DesolatorMagno 2020-06-07 22:42:18
Have you tried searching by id but passing a string?
cayetanohosma 2020-06-07 22:42:23
Yes, I know that the string is not an UUID, but It throws an exception instead a rule message
DesolatorMagno 2020-06-07 22:42:50
How can return a validation message if you are not validating.
cayetanohosma 2020-06-07 22:43:12
Due to the validation rule exists:users,id fails
DesolatorMagno 2020-06-07 22:43:20
I like trying to store null in a field that is not nullsble.
cayetanohosma 2020-06-07 22:43:34
Yeah! I know, It will fail
cayetanohosma 2020-06-07 22:44:01
How does you suggest to catch that and return a rule message?
DesolatorMagno 2020-06-07 22:44:33
You are not f**ckin validating the type of data, only if it is in DB.
DesolatorMagno 2020-06-07 22:44:49
As you would validate a Integer o string.
cayetanohosma 2020-06-07 22:45:36
Maybe I can set a rule as regex in order to be sure that all items match with an UUID format and avoid to look for a malicious values
cayetanohosma 2020-06-07 22:45:56
DesolatorMagno 2020-06-07 22:44:33
You are not f**ckin validating the type of data, only if it is in DB.
Ok, ok
DesolatorMagno 2020-06-07 22:46:23
cayetanohosma 2020-06-07 22:45:36
Maybe I can set a rule as regex in order to be sure that all items match with an UUID format and avoid to look for a malicious values
Yes, that is what I am telling you, you need a rule to check it is in the right format
cayetanohosma 2020-06-07 22:47:29
OK, ok, I didn’t understand you, sorry
DesolatorMagno 2020-06-07 22:47:41
Np
DesolatorMagno 2020-06-07 22:48:17
Remember to always check the type of data, unless is name or description.
cayetanohosma 2020-06-07 22:50:37
DesolatorMagno 2020-06-07 22:48:17
Remember to always check the type of data, unless is name or description.
Yes, that is a mandatory rule!
cayetanohosma 2020-06-07 23:03:29
@DesolatorMagno Do you know how to modify the message in order to change this: “The selected id.0 is invalid.” to something like The UUID does not match with existing UUID
cayetanohosma 2020-06-07 23:04:11
I suppose which is necessary to define the $message array and pass to make, isn’t it?
DesolatorMagno 2020-06-07 23:28:41
The second param for validate is messages, you could try using the array sintaxys to see if work.
erjont 2020-06-08 00:24:10
Hello,who can help me with a problem that i have in a script,i need help from someone who have good experience ?
Thanks 😊
Roham0010 2020-06-08 01:12:53
erjont 2020-06-08 00:24:10
Hello,who can help me with a problem that i have in a script,i need help from someone who have good experience ?
Thanks 😊
You can just say what is the problem
erjont 2020-06-08 01:14:51

@Roham0010 i have made some changes in the script and now imsges do not load
Roham0010 2020-06-08 01:17:24
Roham0010 2020-06-08 01:17:24

Hey guys look at this I really don’t understand it why is this happening?
first image is the code I used pagination then dumped the result and then checked result with == opperator to see it it’s empty the dump data in second image shows that it’s not empty but in goes in if condition
I know I can do it in another ways to check
I want to know why it happened!! 😐
amirAutomationEnginner 2020-06-08 01:18:44
Excuse me.
What is the difference between api and json?
Which one is Better in larave?
Which دو you recommend to Learn?
amirAutomationEnginner 2020-06-08 01:19:23
Thanks for answering
Roham0010 2020-06-08 01:26:09
amirAutomationEnginner 2020-06-08 01:18:44
Excuse me.
What is the difference between api and json?
Which one is Better in larave?
Which دو you recommend to Learn?
API stands for: Application Programming Interface
Its usage is when you want to have a client that can use your application programs so client and your application speak trough the API. client sends a request to your api and api reffers to your application then return the response
And JSON stands for JavaScript Object Notation
It’s just a format of some data and when your api and client speaks together they speak trough this format
Json is a format like this: {“flag”:1}
Roham0010 2020-06-08 01:27:53
Roham0010 2020-06-08 01:17:24
Strange thing is that when I change pagination(10) to pagination(1) it wont recognize it as empty! 😁
matlimaaa 2020-06-08 02:11:57
Galera, boa noite…
Alguém já implementou Real-time usando o Broadcasting do Laravel?
See alguém puder enviar um tutorial eu agradeceria demais… A Docs é um pouco confusa pra mim
alwad3ani 2020-06-08 08:46:47
alwad3ani 2020-06-08 08:46:47

Any one can help me ?
devmansurov 2020-06-08 08:53:33
alwad3ani 2020-06-08 08:46:47
Any one can help me ?
Try $user as $u
devmansurov 2020-06-08 08:56:15
Best solution send $users instead $user to view from controller and then you can use @foreach($users as $user)
MishalLeo 2020-06-08 09:49:27
Anyone using cypress
MishalLeo 2020-06-08 09:49:38
For testing
amirAutomationEnginner 2020-06-08 09:57:31
I am Middle in laravel
What should i do to become Professional in laravel?
2020-06-08 10:55:58
how to pass the data that user selected in view to route and than to controller to call third party post api in laravel
Respuzy 2020-06-08 10:58:05

Plz how do I go about getting this error resolved. I am new to laravel. Thanks
Sujay 2020-06-08 11:28:37
I am using ubuntu 16.04
I change Apache2 server path from /var/www/html/ to /var/www/html/public
Where in public folder our index.php file but this give me
HTTP_ERROR 500
suhailpallimalil 2020-06-08 12:13:03
Anybody done integration with grandstream PBX phones
flyingdragons 2020-06-08 13:25:50
Sujay 2020-06-08 11:28:37
I am using ubuntu 16.04
I change Apache2 server path from /var/www/html/ to /var/www/html/public
Where in public folder our index.php file but this give me
HTTP_ERROR 500
1. try restart Apache once
2. Enable mod rewrite module and then do step1
3. Go to apache.conf and use allow all for /var/www/html folder and then step 1
Maks_Ramazan 2020-06-08 13:52:10
Guys please help me, i’m trying to understand how to implements MS-Wopi, to open doc from my host, i need some tech advice
Siberfx 2020-06-08 14:32:18
show your tables and their structures, then we can understand better.
vikaskumar_99 2020-06-08 14:43:08
Hello DEVELOPERs anyone used rsa library for enycription?
vikaskumar_99 2020-06-08 14:43:52
Please guide me
geekfundz 2020-06-08 15:07:32
Anyone who knows a reliable payment gateway I can integrate with laravel
geekfundz 2020-06-08 15:07:46
For credit cards
jkwya 2020-06-08 15:23:08
geekfundz 2020-06-08 15:07:32
Anyone who knows a reliable payment gateway I can integrate with laravel
https://laravel.com/docs/7.x/billing
Sujay 2020-06-08 15:24:34
flyingdragons 2020-06-08 13:25:50
1. try restart Apache once
2. Enable mod rewrite module and then do step1
3. Go to apache.conf and use allow all for /var/www/html folder and then step 1
This is not working still i get Http error 500
← prev | next →