How to Connect IBM Netezza from .net Core 2.0
How to Connect IBM Netezza database from .net Core 2.0 I am not able to find what driver is required to connect , I am working on VS 2017 and will be deploying it on openshift platform on linux
See also questions close to this topic
Netezza - Issue while passing parameters to Netezza using SSRS application
I am trying to pass 2 date type values using parameters to Netezza database and the application is SSRS. Eg Netezza Query: WHEN (PROCESS_DATE to_date(@Start_Date, 'YYYY-MM-DD') and to_date(@End_Date, 'YYYY-MM-DD')) THEN 'Q4 2018' Here we have 2 parameters @Start_Date and @End_Date which are input to user and then I am trying to pass this to Netezza but I am getting issue.
Not sure I am passing the parameters to Netezza it in correct way.
Have tried many solutions provided via google serach but none of them worked
WHEN (PROCESS_DATE BETWEEN to_date(@Start_Date, 'YYYY-MM-DD') and to_date(@End_Date, 'YYYY-MM-DD')) THEN 'Q4 2018'
Expecting something like this after passing the 2 parameters: User has passed @Start_Date = '2018-10-01' and @End_Date = '2018-12-31' Result: WHEN (PROCESS_DATE BETWEEN to_date('2018-10-01', 'YYYY-MM-DD') and to_date('2018-12-31', 'YYYY-MM-DD')) THEN 'Q4 2018'
Invalid Position in SQL WHERE Clause
I have a query I am writing that examines an ID field and derives and ID number from that column based on several criteria. Now that it's I have that logic written, I want to run the query on each criteria to see if the logic is working. So, the last part of my query for doing so is as follows:
FROM TABLE1 WHERE SOURCE_SYSTEM_NM = 'XYZ' AND ((STRLEFT(SOURCE_ARRANGEMENT_ID,4)) NOT IN ('23CC','21CC')) LIMIT 10000
Essentailly what I am trying to do here is tell it to return to me only items with SOURCE_SYSTEM_NM as 'XYZ', but also of those, eliminate any that have a SOURCE_ARRANGEMENT_ID that does not have the first 4 characters '21CC' or '23CC'. I actually have a third criteria I want to filter out as well, which is the first three characters being '0CC'.
My problem when I run this is I get back an "Invalid Position" error. I removed one of the strings from the criteria, and it works. So, I decided to add the second in it's own 'NOT IN...' clause with an AND between them, but that resulted in the same error.
If I had to guess, the
NOT IN ('21CC','23CC')puts and AND between them and I think that must be the root of my issue. The criteria in my CASE statement derives the ID number with the following:
WHEN (M_CRF_CU_PRODUCT_ARRANGEMENT.SOURCE_SYSTEM_NM) IN ('XYZ') AND STRLEFT(SOURCE_ARRANGEMENT_ID, 4) IN ('23CC','21CC') THEN STRRIGHT(SOURCE_ARRANGEMENT_ID, LENGTH(SOURCE_ARRANGEMENT_ID)-4) WHEN (M_CRF_CU_PRODUCT_ARRANGEMENT.SOURCE_SYSTEM_NM) IN ('XYZ') AND STRLEFT(SOURCE_ARRANGEMENT_ID, 3) IN ('0CC') THEN STRRIGHT(SOURCE_ARRANGEMENT_ID, LENGTH(SOURCE_ARRANGEMENT_ID)-3) WHEN (M_CRF_CU_PRODUCT_ARRANGEMENT.SOURCE_SYSTEM_NM) IN ('XYZ') AND (STRLEFT(SOURCE_ARRANGEMENT_ID, 4) NOT IN ('23CC','21CC') OR STRLEFT(SOURCE_ARRANGEMENT_ID, 3) NOT IN ('0CC')) THEN (SOURCE_ARRANGEMENT_ID)
So with that, I am just trying to check each criteria to make sure the ID derived/created is correct. I need to filter down to get results for that last WHEN statement above, but I keep getting that "Invalid Position" in my WHERE statement at the end. I am using Aginity to run this query and it's against and IBM Netezza database. Thanks in advance!
Is there any equivalent Double Metaphone algorithm in Python as same as Netezza dbl_mp?
I'm trying to create a Python UDF as equivalent to Netezza dbl_mp in the Redshift cluster.
I could see that the existing Python Metaphone or Phonetics Packages are not working as similar to the Netezza dbl_mp.
I've tried to get the Output with the existing python packages [Metaphone, Phonetics] and it seems I'm not getting similar output as Netezza. How can I achieve this? or How can I do the Similar Algorithm in Python as same as Netezza Double Metaphone?
It would be great ! If I get any Suggestions or Help on this !!!
Thanks in Advance
#With Phonetics import phonetics as ph print(ph.dmetaphone('Steve')) #With Metaphone import metaphone as mp print(mp.dm('Steve'))
print(mp.dm('Steve'))==> ('STF', '')
"I expect the output of 'Steve' to be '-852439760', but the actual is ('STF', '')."