bug found in SQL 1.3.0-rc.2-dev master-9d8d010

General discussion of Mantis.

Moderators: Developer, Contributor

Post Reply
AlexeiK
Posts: 31
Joined: 11 Jan 2016, 10:29

bug found in SQL 1.3.0-rc.2-dev master-9d8d010

Post by AlexeiK »

$t_where2 = 'AND bt.project_id = ' . db_param();

no space before AND custom_field_api.php:1090 custom_field_distinct_values() array (


1.3.0-rc.2-dev master-9d8d010
atrol
Site Admin
Posts: 8555
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: bug found in SQL 1.3.0-rc.2-dev master-9d8d010

Post by atrol »

No time to try and to have a deeper look at the moment.
Do you get any problem because of this?
Isn't it enough to have the space in $t_where1?

The forum is not the right place to enter bug reports.
Please use https://www.mantisbt.org/bugs for it.
Please use Search before posting and read the Manual
AlexeiK
Posts: 31
Joined: 11 Jan 2016, 10:29

Re: bug found in SQL 1.3.0-rc.2-dev master-9d8d010

Post by AlexeiK »

yes.
i put a space and it goes fine.
atrol
Site Admin
Posts: 8555
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: bug found in SQL 1.3.0-rc.2-dev master-9d8d010

Post by atrol »

I am not able to reproduce any issue
That's why I asked
atrol wrote: Do you get any problem because of this?
So again my question: Which error do you get?
Please use Search before posting and read the Manual
AlexeiK
Posts: 31
Joined: 11 Jan 2016, 10:29

Re: bug found in SQL 1.3.0-rc.2-dev master-9d8d010

Post by AlexeiK »

APPLICATION ERROR #401
Database query failed. Error received from database was #137: SQLState: 42000
Error Code: 137
Message: [Microsoft][ODBC Driver 11 for SQL Server][SQL Server]Must declare the scalar variable "@P1AND".
for the query: SELECT DISTINCT cfst.value
FROM mantis_custom_field_string_table cfst JOIN mantis_bug_table bt ON bt.id = cfst.bug_id
WHERE cfst.field_id = ?AND bt.project_id = ?
ORDER BY cfst.value.
Please use the "Back" button in your web browser to return to the previous page. There you can correct whatever problems were identified in this error or select another action. You can also click an option from the menu bar to go directly to a new section.
i revert back this code.

you must done two things to get this error:
Project must have Custom field(string in my case) and Version.
Then go to View Issues, change from All Projects to your project and click Resolution filter and others near this field.
Post Reply