-3

in SQL server I can force hint parellelism in execution of query using the HINT 'OPTION(MAXDOP 1)'. Can you please help me with an equivaluent hint in DB2 My query in SQL server

select from table_name option (maxdop 1)

Hello123
  • 1
  • 2
  • Your question is too vague. When asking for help with Db2, always give your Db2-server operating-system (Z/OS, i-Series, Linux/Unix/Windows), and also give your Db2 version. That's because the answers can differ depending on these facts. Db2 (current versions) has different techniques for supplying hints. – mao Jul 18 '18 at 06:56
  • Am using DB2 as source in my Data Migration . From SSIS tool, I have added DB2 as ODBC source. Am writing a SQL query to fetch records from a DB2 table. In Oracle and SQL server I can add query hints while I write the query.Am looking for a way to implement the same in this query as well. I dont have previlige to modify DB parameters . OS-windows. Am not very sure on the version. sorry about that. – Hello123 Jul 18 '18 at 23:49
  • Be specific, is your Db2-server running on Microsoft-Windows? It's essential to know such information before you ask a question. – mao Jul 19 '18 at 05:44

1 Answers1

0

Assuming you are using Db2 for LUW, query parallelism is controlled by the current degree. It does not need to be set as a hint. Parallel processing for applications

Paul Vernon
  • 3,818
  • 1
  • 10
  • 23
  • Am using DB2 as source in SSIS. I have followed this blog to speed up the ETL process. http://henkvandervalk.com/reading-as-fast-as-possible-from-a-table-with-ssis-part-ii . As mentioned in it I dont see any difference in timing without having MAXDOP hint. so looking for a way to implement it in my query – Hello123 Jul 18 '18 at 23:28
  • Also, please tell me if there way to handle it through query without changing any DB parameters – Hello123 Jul 18 '18 at 23:51
  • You might find that your bottleneck is elsewhere, but as you asked.. add e.g. `/**/` to the end of your SQL.. As per https://www.ibm.com/support/knowledgecenter/en/SSEPGG_11.1.0/com.ibm.db2.luw.admin.perf.doc/doc/c0070117.html – Paul Vernon Jul 19 '18 at 08:13